﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace YAPSAR.Domain
{
    public class Process
    {
        public virtual int Id { get; set; }

        /// <summary>
        /// Gets or sets the name of the application.
        /// Usually not required to be set since the more important name is the name of the project, or the name of the window title.
        /// But this can be useful if it's a weird process with no window title, like VSHOST.
        /// </summary>
        public virtual String Name { get; set; }

        public virtual Project Project { get; set; }
        //public virtual String WindowTitle { get; set; }
        public virtual String ExecutableFilePath { get; set; }

        public virtual IList<ProcessTag> Tags { get; set; }
        public virtual IList<ProcessInstance> Instances { get; set; }
        //public virtual IList<TypedWord> TypedWords { get; set; }

        public Process()
        {
            //this.TypedWords = new List<TypedWord>();
            this.Instances = new List<ProcessInstance>();
        }

        public override string ToString()
        {
            return "Project: " + this.Id + " with exe '" + this.ExecutableFilePath + "'";
        }
    }
}
